package cn.itcast.n3_Java线程;

import lombok.extern.slf4j.Slf4j;

/**
 * <p>
 * 观察线程交替执行的现象
 * </p>
 *
 * @author flyduck
 * @since 2023/7/11
 */
@Slf4j(topic = "c.Test02_观察多个线程并发交替执行")
public class Test02_观察多个线程并发交替执行 {
    public static void main(String[] args) {
        new Thread(() -> {
            while (true) {
                log.debug("running");
            }
        },"t1").start();


        new Thread(() -> {
            while (true) {
                log.debug("running");
            }
        },"t2").start();
    }
}
